<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@page import="com.blockchain.console.servlets.trading.jjfq.SfkyJyfq"%>
<%@page import="com.blockchain.console.servlets.trading.jjfq.DeleteJyfq"%>
<%@page import="com.blockchain.console.servlets.trading.jjfq.UpdateJyfq"%>
<%@page import="com.blockchain.console.servlets.trading.jjfq.AddJyfq"%>
<%@page import="com.blockchain.console.servlets.trading.jjfq.JyfqList"%>
<%@page import="com.blockchain.console.service.trading.entity.JyfqEntity"%>
<%@page import="com.blockchain.console.service.trading.entity.XlbEntity"%>
<%@page import="com.sun.org.apache.bcel.internal.generic.ISUB"%>
<%@page import="com.blockchain.common.enums.IsPass"%>
<html>
<head>
<%@include file="/WEB-INF/include/meta.jsp"%>
<%@include file="/WEB-INF/include/style.jsp"%>
</head>
<%
CURRENT_CATEGORY="JYGL";
CURRENT_SUB_CATEGORY="FQGL";
PagingResult<JyfqEntity> jyfqs= (PagingResult<JyfqEntity>)request.getAttribute("jyfqs");
JyfqEntity[]  jyfqArray =jyfqs.getItems();
%>
<body>
	<%@include file="/WEB-INF/include/header.jsp"%>
	<div class="w_main">
		<div class="main clearfix">
			<div class="wrap">
			<form action="<%=controller.getURI(request, JyfqList.class) %>" method="post">
				<div class="r_main">
					<div class="home_main">
						<div class="box box1 mb15">
							<div class="atil">
                    		<h3>交易分区管理</h3>
                  			</div>
						</div>
						<div class="box box1 mb15">
							<div class="clear"></div>
							<div class="con">
							<div class="admin_input admin_pb">
						 		<div class="mt10">
						 			<%if (blockchainSession.isAccessableResource(AddJyfq.class)) {%>
									<a href="<%=controller.getURI(request, AddJyfq.class) %>" class="btn3 mr10"><span class="ico3"></span>添加</a>
									<%}%>
						 			<div class="clear"></div>
								</div>
						    </div>
						</div>
						</div>
						<div>
							<table width="100%" border="0" cellspacing="0" cellpadding="3" class="yhgl_table tc">
						<tr class="hsbg">
                          <td>ID</td>
                          <td>币种/简称</td>
                          <td>分区名称</td>
                          <td>分区英文名</td>
                          <td>排序</td>
                          <td>是否可用</td>
                          <td>时间</td>
                          <td>操作</td>
                        </tr>
						<%
                        if (jyfqArray != null) {for (int i =0;i<jyfqArray.length;i++){JyfqEntity x=jyfqArray[i];if (x == null) {continue;}
                        %>
                        <tr class="dhsbg">
                          <td><%=x.id%></td>
                          <td><%StringHelper.filterHTML(out, x.bzzwm);%>/<%StringHelper.filterHTML(out, x.ywjc);%></td>
                          <td><%StringHelper.filterHTML(out, x.fqmc);%></td>
                          <td><%StringHelper.filterHTML(out, x.fqywm);%></td>
                          <td><%=x.px%></td>
                          <td><%=x.isPass.getName()%></td>
                          <td><%=TimestampParser.format(x.sj)%></td>
                         <td>
                          <%if (blockchainSession.isAccessableResource(UpdateJyfq.class)) {%>
                          	<span class="blue"><a href="<%=controller.getURI(request,UpdateJyfq.class)%>?id=<%=x.id%>" class="mr10">编辑</a></span>
                          <%}%>
                       	<%if (blockchainSession.isAccessableResource(DeleteJyfq.class)){%>
		                     <span class="blue"><a href="javascript:void(0)" onclick="load('<%=controller.getURI(request, DeleteJyfq.class)%>?id=<%=x.id%>')" class="mr10">删除</a></span>
                         <%}%> 
                         <%if (blockchainSession.isAccessableResource(SfkyJyfq.class)&&IsPass.F.toString().equals(x.isPass.name())){%>
		                     <span class="blue"><a href="javascript:void(0)" onclick="load('<%=controller.getURI(request, SfkyJyfq.class)%>?id=<%=x.id%>&sfky=<%=IsPass.S%>')" class="mr10">启用</a></span>
                         <%}%> 
                         <%if (blockchainSession.isAccessableResource(SfkyJyfq.class)&&IsPass.S.toString().equals(x.isPass.name())){%>
		                     <span class="blue"><a href="javascript:void(0)" onclick="load('<%=controller.getURI(request, SfkyJyfq.class)%>?id=<%=x.id%>&sfky=<%=IsPass.F%>')" class="mr10">锁定</a></span>
                         <%}%> 
                          </td>
						</tr>
							<%}}%>
							</table>
						</div>
							<%AbstractConsoleServlet.rendPagingResult(out, jyfqs); %>
						<div class="box2 clearfix"></div>
					</div>
				</div>
				</form>
			</div>
			<%@include file="/WEB-INF/include/left.jsp" %>
		</div>
	</div>
	<%@include file="/WEB-INF/include/footer.jsp"%>
	<%@include file="/WEB-INF/include/script.jsp"%>
	<script type="text/javascript">
		function load(url)
		{
			if (!window.confirm("你确定吗？")) {
				return;
			}
			location.href=url;
		}	
		</script>
</body>
</html>